/*
 *  Copyright 2007-2008 by Matthias Buch-Kromann <mbk.isv@cbs.dk>.
 *  *
 *  This file is part of the Open-source Dependency Toolkit (OSDT),
 *  see http://code.google.com/p/open-source-dependency-toolkit.
 *  
 *  The OSDT is free software: you can redistribute it and/or modify
 *  it under the terms of the GNU Lesser General Public License as 
 *  published by the Free Software Foundation, either version 3 of 
 *  the License, or (at your option) any later version.
 * 
 *  The OSDT is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU Lesser General Public License for more details.
 * 
 *  You should have received a copy of the GNU Lesser General Public 
 *  License along with the OSDT in the files COPYING and COPYING.LESSER.
 *  If not, see http://www.gnu.org/licenses.
 */

package org.osdtsystem.utils;

import java.util.LinkedHashMap;
import java.util.LinkedHashSet;
import java.util.List;
import java.util.Map;
import java.util.Set;
import java.util.SortedSet;

/**
 * Factory for creating storage (persistent/non-persistent, memory/on-disk, cached/non-cached)
 * that can be used to store training data and other data.
 * @author Matthias Buch-Kromann <mbk.isv@cbs.dk>
 */
public interface Storage {
    public <X> List<X> smallList(Object... ids);
    public <X> Set<X> smallSet(Object... ids);
    public <X> SortedSet<X> smallSortedSet(Object... ids);
    public <X> LinkedHashSet<X> smallLinkedHashSet(Object... ids);
    public <X,Y> Map<X,Y> smallMap(Object... ids);
    public <X,Y> LinkedHashMap<X,Y> smallLinkedHashMap(Object... ids);

    public <X> List<X> bigList(Object... ids);
    public <X> Set<X> bigSet(Object... ids);
    public <X> SortedSet<X> bigSortedSet(Object... ids);
    public <X,Y> Map<X,Y> bigMap(Object... ids);

    public <X> List<X> newList(Object... ids);
    public <X> Set<X> newSet(Object... ids);
    public <X> LinkedHashSet<X> newLinkedHashSet(Object... ids);
    public <X,Y> Map<X,Y> newMap(Object... ids);
    public <X,Y> LinkedHashMap<X,Y> newLinkedHashMap(Object... ids);

    public String name(Object... ids);
}
